PROCEDURE DefaultOnDoubleClick (op, from, to: LONGINT);
PROCEDURE InitLayoutDialog;
PROCEDURE Open;
PROCEDURE OpenAux (file, title: ARRAY OF CHAR);
PROCEDURE OpenAuxDialog (file, title: ARRAY OF CHAR);
PROCEDURE OpenBrowser (file, title: ARRAY OF CHAR);
PROCEDURE OpenDoc (file: ARRAY OF CHAR);
PROCEDURE OpenMask (file, title: ARRAY OF CHAR);
PROCEDURE OpenToolDialog (file, title: ARRAY OF CHAR);
PROCEDURE PasteCharGuard (VAR par: Dialog.Par);
PROCEDURE PasteGuard (VAR par: Dialog.Par);
PROCEDURE PasteLCharGuard (VAR par: Dialog.Par);
PROCEDURE PasteView;
PROCEDURE PasteViewGuard (VAR par: Dialog.Par);
PROCEDURE SelectionGuard (VAR par: Dialog.Par);
PROCEDURE SingletonGuard (VAR par: Dialog.Par);
END StdCmds.
StdCmds is a command package which contains many commands and guards which are typically used in menu items (->StdMenuTool) or in hyperlinks (->StdLinks).
The module exports more commands which are not described here; these are the commands and guards for menu items of the Windows standard menus. See the
Menus
text for how these commands are used (only on Windows).
VAR layout: RECORD (Dialog.Interactor)
Interactor for root view layout. The size of the outermost view of a document (root view) may be determined in several different ways. Either it is equal to the window size, to the paper size minus the margins defined in the Page
Setup dialog, or to a particular fixed size. The vertical and horizontal directions can be defined independently.
wType, hType: INTEGER wType IN {0..2} & hType IN {0..2}
Determines whether the root view size (horizontical/vertical) has a fixed size (0), the size defined by the Page
Setup dialog (1), or by the window (2).
width, height: REAL valid iff wType/hType = 1
The root view width/height in centimeters.
Ok: PROCEDURE
Set the selected root view to the interactor values.
PROCEDURE CaretGuard (VAR par: Dialog.Par)
Disables menu item if there is no current caret, i.e. no selection of length 0.
PROCEDURE CloseDialog
This command can be used from within a control to close the window in which the control is embedded. It can only be used as reaction to interactive manipulation of the control, i.e. when the mouse is clicked in the control or when it receives keyboard input. If the window is a document window and its contents dirty, an error message will be displayed.
must be called in interaction with control 20
PROCEDURE CopyGuard (VAR par: Dialog.Par)
Disables menu item if there is no selection, or if it cannot be copied.
PROCEDURE CutGuard (VAR par: Dialog.Par)
Disables menu item if there is no selection, or if it cannot be cut.
PROCEDURE DefaultOnDoubleClick (op, from, to: LONGINT)
A standard notifier which "clicks" the default button when its control is double-clicked. Typically, this is used in selection boxes or combo boxes.
PROCEDURE HeightGuard (VAR par: Dialog.Par)
Guard command which sets par.readOnly if layout.hType # 0, i.e. if mode is not "fixed".
PROCEDURE InitLayoutDialog
Initialization command for layout interactor.
PROCEDURE Open
Guard: a view was deposited
Takes a deposited view from the global view queue and opens it in a new window.
PROCEDURE OpenAux (file, title: ARRAY OF CHAR)
Takes a file specification of an Oberon/F document and a window title as parameters, and opens an auxiliary window with the specified title. Parameter file must be the path name of a file.
Auxiliary windows are used for displaying temporary editable data.
Example:
"StdCmds.OpenAux('Form/Mod/List', 'List')"
PROCEDURE OpenAuxDialog (file, title: ARRAY OF CHAR)
Takes a file specification of an Oberon/F document and a window title as parameters, and opens a dialog with the specified document. The dialog is opened as an auxiliary window. Parameter file must be the path name of a file.
Auxiliary dialogs are used for self-contained dialogs, i.e. data entry masks or parameter entry masks for commands.
In contrast to OpenAux, OpenAuxDialog turns the opened document into mask mode if it is a container (-> Containers), and opens it into a dialog window if the underlying platform distinguishes between document and dialog windows (e.g. as in Windows).
PROCEDURE OpenBrowser (file, title: ARRAY OF CHAR)
Takes a file specification of an Oberon/F document and a window title as parameters, and opens the specified document in an auxiliary window. The window contents is not editable, but can be selected. Parameter file must be the path name of a file.
Browser windows are used for displaying documentation. It is possible to select and copy out browser window contents. It is possible to apply find & replace commands, the Info->Interface command, etc.
Takes a file specification of an Oberon/F document as parameter, and opens the document in a document window. Parameter file must be the path name of a file. If the same file is already open in an existing document window, this window is brought to the top, instead of opening a new window.
Document windows are used for displaying persistent editable data.
Example:
"StdCmds.OpenDoc('System/Rsrc/Menus')"
PROCEDURE OpenMask (file, title: ARRAY OF CHAR)
Obsolete. Use OpenBrowser instead.
PROCEDURE OpenToolDialog (file, title: ARRAY OF CHAR)
Takes a file specification of an Oberon/F document and a window title as parameters, and opens a dialog with the specified document. The dialog is opened as tool window. Parameter file must be the path name of a file.
Tool dialogs are used for dialogs which operate on document windows beneath them, e.g. a find & replace dialog which operates on a text under it. Otherwise it is identical to OpenAuxDialog.